home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Collection of Tools & Utilities
/
Collection of Tools and Utilities.iso
/
fortran
/
libry51.zip
/
LIBRY1.DOC
< prev
next >
Wrap
Text File
|
1989-11-10
|
4KB
|
76 lines
.pn 1
.pa
REQUIREMENTS AND CONVENTIONS
LIBRY is an indexed collection of object modules that can be linked to other
FORTRAN object modules. An object module is a binary file produced by a
compiler that contains machine instructions, data, and linker flags. LIBRY
contains object modules written in both assembler and FORTRAN. The linker will
take the object module created by your FORTRAN compiler, add to it what it
needs from LIBRY, and create an executable module. In order to run any
program, you must convert it through these steps into an executable module
(unless you are running interpretive BASIC). LIBRY is also compatible with a
few other programming languages; however, BASIC is not one of these. If all
you have is BASIC don't bother reading any further. LIBRY is only available in
object module form (the source codes are not available under any
circumstances).
On the PC, LIBRY is contained in the file LIBRY.LIB. On the HP-1000F, LIBRY is
contained in the file %LIBRY. On the HP-A900, LIBRY is contained in the file
LIBRY.REL.
In order to produce a compatible object module, you must have a Microsoft
FORTRAN compiler (version 3.31 or later) or HP FTN7X. In order to link your
object module and LIBRY, you must have a Microsoft linker (LINK version 3.0 or
later - I don't know what versions of LINK that come with DOS are compatible -
you get LINK when you purchase FORTRAN anyway) or HP LOADR or LINK. Your LINK
(or DOS) manual will tell you how to access a library. Refer to the LOADR or
LINK manuals for HP applications.
If you are using a PC you also need two other libraries that come with
Microsoft FORTRAN (FORTRAN.LIB and MATH.LIB). Do not attempt to link
LIBRY.LIB with an object module created by a FORTRAN compiler other than
Microsoft's. Do not attempt to link LIBRY.LIB with an object module created
by anyone's BASIC compiler. Do not attempt to link LIBRY.LIB with either of
the two optional math libraries that come with Microsoft FORTRAN (8087.LIB or
ALTMATH.LIB).
If you are using Microsoft FORTRAN don't use any of the following metacommands
in your FORTRAN source code: $LARGE, $DECMATH, $NOFLOATCALLS, or $STORAGE:4
as they will make your object module incompatible with LIBRY.LIB.
All integers passed to LIBRY routines must be of the type INTEGER*2. Put
IMPLICIT INTEGER*2 (I-N)
in EVERY program segment (this greatly increases speed too). You must use the
"/FPi" and "/4I2" options when using Microsoft FORTRAN/V4.0 or later. All
reals must be of the type REAL*4. Put
IMPLICIT REAL*4 (A-H,O-Z)
in EVERY program segment. All double precision reals must be of the type
REAL*8. Put
IMPLICIT REAL*8 (A-H,O-Z)
in each program segment where double precision reals are used. Remember that
all double precision constants must have a "D" in them in order to allocate
the proper space (don't pass "0." as a constant to a routine expecting a
double precision real - use "0.D0"). All logicals must be of the type
LOGICAL*2. Character variables can be of any length (I hate FORTRAN compilers
that permit only fixed length character variables so I do all character
manipulation in assembler).
If you are using a PC you don't need a math coprocessor (Intel 8087/287/387)
in order to run a program linked with LIBRY; but it makes a TREMENDOUS
difference (a factor of 20 to 120 for floating point operations). The vector
emulations will run even without a math coprocessor; but in that case the
speed is already so slow that nothing will help. The improvement in speed with
the vector emulations varies depending on the relative speed of your processor
and coprocessor (not MHz speed but MIPS and FLOPS - a 5MHz-80286 is quite a
bit faster than a 5MHz-8088 while a 5MHz-8087 is just as fast as a 5MHz
80287). The greatest improvement is realized on a PC with a
5MHz-8088/5MHz-8087 pair; and the least improvement is realized on an AT with
an 8MHz-80286/5MHz-80287 pair.